package com.yesep.learn.mqtt.client.common.event;

import io.netty.handler.codec.mqtt.MqttMessage;

/**
 * 
 * @Description:
 */
public class MqttEvent {

	private final EventKey key;
	private final MqttMessage message;

	public MqttEvent(EventKey key, MqttMessage message) {
		this.key = key;
		this.message = message;
	}

	/**
	 * get event key
	 *
	 * @return {@link EventKey}
	 */
	public EventKey getKey() {
		return key;
	}

	/**
	 * get event message
	 *
	 * @return {@link MqttMessage}
	 */
	public MqttMessage getMessage() {
		return message;
	}
}
